home *** CD-ROM | disk | FTP | other *** search
/ TeX 1995 July / TeX CD-ROM July 1995 (Disc 1)(Walnut Creek)(1995).ISO / macros / plain / contrib / calendar / calend0.tex < prev    next >
LaTeX Document  |  1993-09-06  |  4.1 KB

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: LaTeX Document (document/latex).

ConfidenceProgramDetectionMatch TypeSupport
100% dexvert LaTeX Document (document/latex) magic Supported
100% dexvert Texinfo Document (document/texInfo) magic Supported
1% dexvert Corel 10 Texture (image/corel10Texture) ext Unsupported
1% dexvert Croteam texture file (image/croteamTextureFile) ext Unsupported
1% dexvert Text File (text/txt) fallback Supported
100% file TeX document text default
99% file LaTeX document text default
98% file LaTeX auxiliary file, ASCII text default
100% checkBytes Printable ASCII default
100% perlTextCheck Likely Text (Perl) default
100% detectItEasy Format: plain text[LF] default (weak)
100% xdgMime text/x-matlab default (weak)



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 25 25 0a 25 25 20 20 20 | 20 46 49 4c 45 20 63 61 |%%.%% | FILE ca|
|00000010| 6c 65 6e 64 30 2e 74 65 | 78 0a 25 25 20 20 20 20 |lend0.te|x.%% |
|00000020| 4d 6f 64 69 66 69 63 61 | 74 20 39 2f 31 32 2f 39 |Modifica|t 9/12/9|
|00000030| 32 0a 5c 63 61 74 63 6f | 64 65 60 5c 40 3d 31 31 |2.\catco|de`\@=11|
|00000040| 0a 5c 6e 65 77 69 66 5c | 69 66 6c 65 61 70 79 65 |.\newif\|ifleapye|
|00000050| 61 72 0a 5c 64 65 66 5c | 6c 6f 61 64 61 64 76 61 |ar.\def\|loadadva|
|00000060| 6e 63 65 64 7b 25 0a 20 | 5c 69 6e 70 75 74 20 63 |nced{%. |\input c|
|00000070| 61 6c 65 6e 64 31 2e 74 | 65 78 5c 72 65 6c 61 78 |alend1.t|ex\relax|
|00000080| 7d 0a 5c 6e 65 77 63 6f | 75 6e 74 5c 64 61 74 65 |}.\newco|unt\date|
|00000090| 0a 5c 6e 65 77 63 6f 75 | 6e 74 5c 77 65 65 6b 64 |.\newcou|nt\weekd|
|000000a0| 0a 5c 6e 65 77 63 6f 75 | 6e 74 5c 59 65 61 72 0a |.\newcou|nt\Year.|
|000000b0| 5c 6e 65 77 63 6f 75 6e | 74 5c 79 65 61 72 62 61 |\newcoun|t\yearba|
|000000c0| 73 65 0a 5c 6e 65 77 63 | 6f 75 6e 74 5c 4d 6f 6e |se.\newc|ount\Mon|
|000000d0| 74 68 0a 5c 6e 65 77 63 | 6f 75 6e 74 5c 44 61 79 |th.\newc|ount\Day|
|000000e0| 0a 5c 6e 65 77 63 6f 75 | 6e 74 5c 40 63 61 74 63 |.\newcou|nt\@catc|
|000000f0| 68 0a 5c 6e 65 77 63 6f | 75 6e 74 5c 74 69 6d 65 |h.\newco|unt\time|
|00000100| 7a 6f 6e 65 5c 74 69 6d | 65 7a 6f 6e 65 3d 30 0a |zone\tim|ezone=0.|
|00000110| 5c 64 65 66 5c 73 65 74 | 79 65 61 72 23 31 7b 5c |\def\set|year#1{\|
|00000120| 59 65 61 72 3d 23 31 0a | 20 5c 61 64 76 61 6e 63 |Year=#1.| \advanc|
|00000130| 65 5c 59 65 61 72 20 62 | 79 2d 31 39 30 30 5c 63 |e\Year b|y-1900\c|
|00000140| 61 6c 63 75 6c 61 74 65 | 79 65 61 72 62 61 73 65 |alculate|yearbase|
|00000150| 7d 0a 5c 64 65 66 5c 6e | 65 78 74 79 65 61 72 7b |}.\def\n|extyear{|
|00000160| 5c 61 64 76 61 6e 63 65 | 5c 59 65 61 72 20 62 79 |\advance|\Year by|
|00000170| 31 0a 20 5c 63 61 6c 63 | 75 6c 61 74 65 79 65 61 |1. \calc|ulateyea|
|00000180| 72 62 61 73 65 7d 0a 5c | 64 65 66 5c 73 65 74 74 |rbase}.\|def\sett|
|00000190| 69 6d 65 7a 6f 6e 65 23 | 31 7b 5c 74 69 6d 65 7a |imezone#|1{\timez|
|000001a0| 6f 6e 65 3d 23 31 0a 20 | 5c 6d 75 6c 74 69 70 6c |one=#1. |\multipl|
|000001b0| 79 5c 74 69 6d 65 7a 6f | 6e 65 20 62 79 20 31 30 |y\timezo|ne by 10|
|000001c0| 30 30 0a 20 5c 64 69 76 | 69 64 65 5c 74 69 6d 65 |00. \div|ide\time|
|000001d0| 7a 6f 6e 65 20 62 79 32 | 34 7d 0a 25 20 5c 69 66 |zone by2|4}.% \if|
|000001e0| 6c 65 61 70 79 65 61 72 | 20 69 73 20 73 65 74 3b |leapyear| is set;|
|000001f0| 0a 25 20 5c 79 65 61 72 | 62 61 73 65 20 69 73 20 |.% \year|base is |
|00000200| 20 74 68 65 20 6e 75 6d | 62 65 72 20 6f 66 0a 25 | the num|ber of.%|
|00000210| 20 64 61 79 73 20 70 61 | 73 73 65 64 20 66 72 6f | days pa|ssed fro|
|00000220| 6d 20 31 39 30 30 2c 20 | 4a 61 6e 20 30 0a 25 20 |m 1900, |Jan 0.% |
|00000230| 74 6f 20 4e 65 77 20 79 | 65 61 72 27 73 20 64 61 |to New y|ear's da|
|00000240| 74 65 3b 0a 5c 64 65 66 | 5c 63 61 6c 63 75 6c 61 |te;.\def|\calcula|
|00000250| 74 65 79 65 61 72 62 61 | 73 65 7b 25 0a 20 5c 79 |teyearba|se{%. \y|
|00000260| 65 61 72 62 61 73 65 3d | 2d 31 0a 20 7b 5c 63 6f |earbase=|-1. {\co|
|00000270| 75 6e 74 30 3d 5c 59 65 | 61 72 5c 64 69 76 69 64 |unt0=\Ye|ar\divid|
|00000280| 65 5c 63 6f 75 6e 74 30 | 20 62 79 34 0a 20 5c 6d |e\count0| by4. \m|
|00000290| 75 6c 74 69 70 6c 79 5c | 63 6f 75 6e 74 30 20 62 |ultiply\|count0 b|
|000002a0| 79 34 0a 20 5c 69 66 6e | 75 6d 5c 59 65 61 72 3d |y4. \ifn|um\Year=|
|000002b0| 5c 63 6f 75 6e 74 30 0a | 20 5c 67 6c 6f 62 61 6c |\count0.| \global|
|000002c0| 5c 40 63 61 74 63 68 3d | 30 5c 65 6c 73 65 5c 67 |\@catch=|0\else\g|
|000002d0| 6c 6f 62 61 6c 5c 40 63 | 61 74 63 68 3d 31 5c 66 |lobal\@c|atch=1\f|
|000002e0| 69 7d 25 0a 20 5c 69 66 | 63 61 73 65 5c 40 63 61 |i}%. \if|case\@ca|
|000002f0| 74 63 68 20 5c 6c 65 61 | 70 79 65 61 72 74 72 75 |tch \lea|pyeartru|
|00000300| 65 5c 6f 72 0a 20 20 5c | 6c 65 61 70 79 65 61 72 |e\or. \|leapyear|
|00000310| 66 61 6c 73 65 5c 66 69 | 0a 20 7b 5c 63 6f 75 6e |false\fi|. {\coun|
|00000320| 74 30 3d 5c 59 65 61 72 | 5c 6d 75 6c 74 69 70 6c |t0=\Year|\multipl|
|00000330| 79 5c 63 6f 75 6e 74 30 | 0a 20 62 79 31 34 36 31 |y\count0|. by1461|
|00000340| 5c 61 64 76 61 6e 63 65 | 5c 63 6f 75 6e 74 30 20 |\advance|\count0 |
|00000350| 62 79 33 0a 20 5c 64 69 | 76 69 64 65 5c 63 6f 75 |by3. \di|vide\cou|
|00000360| 6e 74 30 20 62 79 34 0a | 20 5c 67 6c 6f 62 61 6c |nt0 by4.| \global|
|00000370| 5c 40 63 61 74 63 68 3d | 5c 63 6f 75 6e 74 30 7d |\@catch=|\count0}|
|00000380| 25 0a 20 5c 61 64 76 61 | 6e 63 65 5c 79 65 61 72 |%. \adva|nce\year|
|00000390| 62 61 73 65 20 62 79 5c | 40 63 61 74 63 68 0a 20 |base by\|@catch. |
|000003a0| 5c 69 66 6e 75 6d 5c 59 | 65 61 72 3d 30 5c 79 65 |\ifnum\Y|ear=0\ye|
|000003b0| 61 72 62 61 73 65 3d 30 | 5c 6c 65 61 70 79 65 61 |arbase=0|\leapyea|
|000003c0| 72 66 61 6c 73 65 5c 66 | 69 7d 0a 25 20 20 47 69 |rfalse\f|i}.% Gi|
|000003d0| 76 65 73 20 74 68 65 20 | 6e 75 6d 62 65 72 20 6f |ves the |number o|
|000003e0| 66 20 64 61 79 73 20 70 | 61 73 73 65 64 0a 25 20 |f days p|assed.% |
|000003f0| 20 61 74 20 74 68 65 20 | 65 6e 64 20 6f 66 20 65 | at the |end of e|
|00000400| 61 63 68 20 6d 6f 6e 74 | 68 2e 0a 25 20 20 56 61 |ach mont|h..% Va|
|00000410| 6c 75 65 20 72 65 74 75 | 72 6e 65 64 20 69 6e 20 |lue retu|rned in |
|00000420| 5c 44 61 79 0a 5c 64 65 | 66 5c 6d 6f 6e 74 68 64 |\Day.\de|f\monthd|
|00000430| 61 79 73 7b 5c 67 6c 6f | 62 61 6c 0a 20 5c 40 63 |ays{\glo|bal. \@c|
|00000440| 61 74 63 68 3d 5c 69 66 | 63 61 73 65 5c 4d 6f 6e |atch=\if|case\Mon|
|00000450| 74 68 20 30 5c 6f 72 33 | 31 5c 6f 72 0a 20 20 35 |th 0\or3|1\or. 5|
|00000460| 39 5c 6f 72 39 30 5c 6f | 72 31 32 30 5c 6f 72 31 |9\or90\o|r120\or1|
|00000470| 35 31 5c 6f 72 31 38 31 | 5c 6f 72 32 31 32 5c 6f |51\or181|\or212\o|
|00000480| 72 0a 20 20 32 34 33 5c | 6f 72 32 37 33 5c 6f 72 |r. 243\|or273\or|
|00000490| 33 30 34 5c 6f 72 33 33 | 34 5c 6f 72 33 36 35 5c |304\or33|4\or365\|
|000004a0| 66 69 0a 20 7b 5c 69 66 | 6c 65 61 70 79 65 61 72 |fi. {\if|leapyear|
|000004b0| 5c 69 66 6e 75 6d 5c 4d | 6f 6e 74 68 3e 31 0a 20 |\ifnum\M|onth>1. |
|000004c0| 20 5c 67 6c 6f 62 61 6c | 5c 61 64 76 61 6e 63 65 | \global|\advance|
|000004d0| 5c 40 63 61 74 63 68 20 | 62 79 31 5c 66 69 5c 66 |\@catch |by1\fi\f|
|000004e0| 69 7d 25 0a 20 5c 44 61 | 79 3d 5c 40 63 61 74 63 |i}%. \Da|y=\@catc|
|000004f0| 68 7d 0a 25 20 4c 6f 6e | 67 20 64 61 74 65 20 6f |h}.% Lon|g date o|
|00000500| 66 20 5c 4d 6f 6e 74 68 | 2c 20 5c 44 61 79 0a 25 |f \Month|, \Day.%|
|00000510| 20 69 6e 20 74 68 65 20 | 79 65 61 72 20 5c 59 65 | in the |year \Ye|
|00000520| 61 72 2e 0a 25 20 56 61 | 6c 75 65 20 72 65 74 75 |ar..% Va|lue retu|
|00000530| 72 6e 65 64 20 69 6e 20 | 5c 64 61 74 65 0a 5c 64 |rned in |\date.\d|
|00000540| 65 66 5c 64 61 79 6e 6f | 7b 5c 64 61 74 65 3d 5c |ef\dayno|{\date=\|
|00000550| 44 61 79 7b 5c 61 64 76 | 61 6e 63 65 0a 20 5c 4d |Day{\adv|ance. \M|
|00000560| 6f 6e 74 68 20 62 79 2d | 31 5c 6d 6f 6e 74 68 64 |onth by-|1\monthd|
|00000570| 61 79 73 0a 20 5c 61 64 | 76 61 6e 63 65 5c 64 61 |ays. \ad|vance\da|
|00000580| 74 65 20 62 79 5c 44 61 | 79 0a 20 5c 67 6c 6f 62 |te by\Da|y. \glob|
|00000590| 61 6c 5c 61 64 76 61 6e | 63 65 5c 64 61 74 65 20 |al\advan|ce\date |
|000005a0| 62 79 5c 79 65 61 72 62 | 61 73 65 7d 7d 0a 25 20 |by\yearb|ase}}.% |
|000005b0| 4c 6f 6e 67 20 64 61 74 | 65 20 4d 4f 44 20 37 20 |Long dat|e MOD 7 |
|000005c0| 67 69 76 65 73 20 74 68 | 65 20 77 65 65 6b 20 64 |gives th|e week d|
|000005d0| 61 79 2e 0a 25 20 53 75 | 6e 64 61 79 20 69 73 20 |ay..% Su|nday is |
|000005e0| 30 20 61 6e 64 20 53 61 | 74 75 72 64 61 79 20 69 |0 and Sa|turday i|
|000005f0| 73 20 36 2e 0a 5c 64 65 | 66 5c 77 65 65 6b 64 61 |s 6..\de|f\weekda|
|00000600| 79 7b 7b 5c 63 6f 75 6e | 74 30 3d 5c 64 61 74 65 |y{{\coun|t0=\date|
|00000610| 5c 72 65 6c 61 78 0a 20 | 5c 63 6f 75 6e 74 31 3d |\relax. |\count1=|
|00000620| 5c 63 6f 75 6e 74 30 5c | 64 69 76 69 64 65 5c 63 |\count0\|divide\c|
|00000630| 6f 75 6e 74 30 20 62 79 | 20 37 0a 20 5c 6d 75 6c |ount0 by| 7. \mul|
|00000640| 74 69 70 6c 79 5c 63 6f | 75 6e 74 30 20 62 79 20 |tiply\co|unt0 by |
|00000650| 37 0a 5c 61 64 76 61 6e | 63 65 5c 63 6f 75 6e 74 |7.\advan|ce\count|
|00000660| 31 20 62 79 20 2d 5c 63 | 6f 75 6e 74 30 0a 20 5c |1 by -\c|ount0. \|
|00000670| 67 6c 6f 62 61 6c 5c 77 | 65 65 6b 64 3d 5c 63 6f |global\w|eekd=\co|
|00000680| 75 6e 74 31 7d 7d 0a 25 | 20 4e 61 6d 65 20 6f 66 |unt1}}.%| Name of|
|00000690| 20 77 65 65 6b 20 64 61 | 79 20 28 4c 6f 63 61 6c | week da|y (Local|
|000006a0| 29 2e 0a 5c 64 65 66 5c | 74 68 65 77 65 65 6b 64 |)..\def\|theweekd|
|000006b0| 61 79 7b 5c 77 65 65 6b | 64 61 79 0a 20 5c 69 66 |ay{\week|day. \if|
|000006c0| 63 61 73 65 5c 77 65 65 | 6b 64 0a 20 53 75 6e 64 |case\wee|kd. Sund|
|000006d0| 61 79 5c 6f 72 20 4d 6f | 6e 64 61 79 5c 6f 72 20 |ay\or Mo|nday\or |
|000006e0| 54 75 65 73 64 61 79 5c | 6f 72 0a 20 57 65 64 6e |Tuesday\|or. Wedn|
|000006f0| 65 73 64 61 79 5c 6f 72 | 20 54 68 75 72 73 64 61 |esday\or| Thursda|
|00000700| 79 5c 6f 72 20 46 72 69 | 64 61 79 5c 6f 72 0a 20 |y\or Fri|day\or. |
|00000710| 53 61 74 75 72 64 61 79 | 5c 66 69 7d 0a 25 20 28 |Saturday|\fi}.% (|
|00000720| 4c 6f 63 61 6c 29 0a 5c | 64 65 66 5c 74 68 65 73 |Local).\|def\thes|
|00000730| 68 6f 72 74 77 65 65 6b | 64 61 79 7b 5c 77 65 65 |hortweek|day{\wee|
|00000740| 6b 64 61 79 0a 20 5c 69 | 66 63 61 73 65 5c 77 65 |kday. \i|fcase\we|
|00000750| 65 6b 64 20 53 75 6e 5c | 6f 72 20 4d 6f 6e 5c 6f |ekd Sun\|or Mon\o|
|00000760| 72 20 54 75 65 5c 6f 72 | 0a 20 20 57 65 64 5c 6f |r Tue\or|. Wed\o|
|00000770| 72 20 54 68 75 5c 6f 72 | 20 46 72 69 5c 6f 72 20 |r Thu\or| Fri\or |
|00000780| 53 61 74 5c 66 69 7d 0a | 25 20 47 69 76 65 73 20 |Sat\fi}.|% Gives |
|00000790| 74 68 65 20 75 73 75 61 | 6c 20 63 61 6c 65 6e 64 |the usua|l calend|
|000007a0| 61 72 20 64 61 74 65 20 | 66 6f 72 0a 25 20 61 20 |ar date |for.% a |
|000007b0| 6c 6f 6e 67 20 64 61 74 | 65 20 69 6e 20 63 6f 75 |long dat|e in cou|
|000007c0| 6e 74 65 72 20 5c 64 61 | 74 65 2e 0a 25 20 52 65 |nter \da|te..% Re|
|000007d0| 74 75 72 6e 65 64 20 69 | 6e 20 5c 44 61 79 2c 20 |turned i|n \Day, |
|000007e0| 5c 4d 6f 6e 74 68 20 61 | 6e 64 20 5c 59 65 61 72 |\Month a|nd \Year|
|000007f0| 0a 5c 64 65 66 5c 63 61 | 6c 64 61 74 65 7b 5c 59 |.\def\ca|ldate{\Y|
|00000800| 65 61 72 3d 5c 64 61 74 | 65 0a 20 5c 6d 75 6c 74 |ear=\dat|e. \mult|
|00000810| 69 70 6c 79 5c 59 65 61 | 72 20 62 79 34 5c 64 69 |iply\Yea|r by4\di|
|00000820| 76 69 64 65 5c 59 65 61 | 72 20 62 79 31 34 36 31 |vide\Yea|r by1461|
|00000830| 0a 20 5c 63 61 6c 63 75 | 6c 61 74 65 79 65 61 72 |. \calcu|lateyear|
|00000840| 62 61 73 65 0a 20 7b 5c | 61 64 76 61 6e 63 65 5c |base. {\|advance\|
|00000850| 64 61 74 65 20 62 79 2d | 5c 79 65 61 72 62 61 73 |date by-|\yearbas|
|00000860| 65 5c 4d 6f 6e 74 68 3d | 30 0a 20 5c 6c 6f 6f 70 |e\Month=|0. \loop|
|00000870| 5c 6d 6f 6e 74 68 64 61 | 79 73 5c 69 66 6e 75 6d |\monthda|ys\ifnum|
|00000880| 5c 44 61 79 3c 5c 64 61 | 74 65 0a 20 5c 67 6c 6f |\Day<\da|te. \glo|
|00000890| 62 61 6c 5c 61 64 76 61 | 6e 63 65 5c 4d 6f 6e 74 |bal\adva|nce\Mont|
|000008a0| 68 20 62 79 31 5c 72 65 | 70 65 61 74 0a 20 7b 5c |h by1\re|peat. {\|
|000008b0| 61 64 76 61 6e 63 65 5c | 4d 6f 6e 74 68 20 62 79 |advance\|Month by|
|000008c0| 2d 31 5c 6d 6f 6e 74 68 | 64 61 79 73 0a 20 5c 61 |-1\month|days. \a|
|000008d0| 64 76 61 6e 63 65 5c 64 | 61 74 65 20 62 79 2d 5c |dvance\d|ate by-\|
|000008e0| 44 61 79 0a 20 5c 67 6c | 6f 62 61 6c 5c 44 61 79 |Day. \gl|obal\Day|
|000008f0| 3d 5c 64 61 74 65 7d 7d | 7d 0a 25 20 4e 61 6d 65 |=\date}}|}.% Name|
|00000900| 20 6f 66 20 6d 6f 6e 74 | 68 20 5c 4d 6f 6e 74 68 | of mont|h \Month|
|00000910| 2e 20 28 4c 6f 63 61 6c | 29 0a 5c 64 65 66 5c 74 |. (Local|).\def\t|
|00000920| 68 65 6d 6f 6e 74 68 7b | 5c 69 66 63 61 73 65 5c |hemonth{|\ifcase\|
|00000930| 4d 6f 6e 74 68 0a 20 5c | 6f 72 20 4a 61 6e 75 61 |Month. \|or Janua|
|00000940| 72 79 5c 6f 72 20 46 65 | 62 72 75 61 72 79 5c 6f |ry\or Fe|bruary\o|
|00000950| 72 20 4d 61 72 63 68 5c | 6f 72 0a 20 41 70 72 69 |r March\|or. Apri|
|00000960| 6c 5c 6f 72 20 4d 61 79 | 5c 6f 72 20 4a 75 6e 65 |l\or May|\or June|
|00000970| 5c 6f 72 20 4a 75 6c 79 | 5c 6f 72 0a 20 41 75 67 |\or July|\or. Aug|
|00000980| 75 73 74 5c 6f 72 20 53 | 65 70 74 65 6d 62 65 72 |ust\or S|eptember|
|00000990| 5c 6f 72 20 4f 63 74 6f | 62 65 72 5c 6f 72 0a 20 |\or Octo|ber\or. |
|000009a0| 4e 6f 76 65 6d 62 65 72 | 5c 6f 72 20 44 65 63 65 |November|\or Dece|
|000009b0| 6d 62 65 72 5c 66 69 7d | 0a 25 20 46 69 6e 64 20 |mber\fi}|.% Find |
|000009c0| 74 68 65 20 6e 65 78 74 | 20 28 70 72 65 76 69 6f |the next| (previo|
|000009d0| 75 73 29 20 64 61 79 20 | 61 66 74 65 72 0a 25 20 |us) day |after.% |
|000009e0| 28 62 65 66 6f 72 65 29 | 20 5c 64 61 74 65 20 77 |(before)| \date w|
|000009f0| 69 74 68 20 5c 77 65 65 | 6b 64 61 79 3d 23 31 2e |ith \wee|kday=#1.|
|00000a00| 0a 5c 64 65 66 5c 6e 65 | 78 74 64 61 79 23 31 7b |.\def\ne|xtday#1{|
|00000a10| 7b 5c 63 6f 75 6e 74 30 | 3d 23 31 5c 77 65 65 6b |{\count0|=#1\week|
|00000a20| 64 61 79 0a 20 5c 61 64 | 76 61 6e 63 65 5c 63 6f |day. \ad|vance\co|
|00000a30| 75 6e 74 30 20 62 79 2d | 5c 77 65 65 6b 64 0a 20 |unt0 by-|\weekd. |
|00000a40| 5c 69 66 6e 75 6d 5c 63 | 6f 75 6e 74 30 3c 30 5c |\ifnum\c|ount0<0\|
|00000a50| 61 64 76 61 6e 63 65 5c | 63 6f 75 6e 74 30 20 62 |advance\|count0 b|
|00000a60| 79 37 5c 66 69 0a 20 5c | 67 6c 6f 62 61 6c 5c 61 |y7\fi. \|global\a|
|00000a70| 64 76 61 6e 63 65 5c 64 | 61 74 65 20 62 79 5c 63 |dvance\d|ate by\c|
|00000a80| 6f 75 6e 74 30 7d 7d 0a | 5c 64 65 66 5c 70 72 65 |ount0}}.|\def\pre|
|00000a90| 76 64 61 79 23 31 7b 5c | 73 6e 65 78 74 64 61 79 |vday#1{\|snextday|
|00000aa0| 23 31 0a 20 5c 61 64 76 | 61 6e 63 65 5c 64 61 74 |#1. \adv|ance\dat|
|00000ab0| 65 20 62 79 2d 37 7d 0a | 5c 64 65 66 5c 73 6e 65 |e by-7}.|\def\sne|
|00000ac0| 78 74 64 61 79 23 31 7b | 5c 61 64 76 61 6e 63 65 |xtday#1{|\advance|
|00000ad0| 5c 64 61 74 65 20 62 79 | 31 0a 20 5c 6e 65 78 74 |\date by|1. \next|
|00000ae0| 64 61 79 23 31 7d 0a 5c | 64 65 66 5c 73 70 72 65 |day#1}.\|def\spre|
|00000af0| 76 64 61 79 23 31 7b 5c | 61 64 76 61 6e 63 65 5c |vday#1{\|advance\|
|00000b00| 64 61 74 65 20 62 79 2d | 31 0a 20 5c 70 72 65 76 |date by-|1. \prev|
|00000b10| 64 61 79 23 31 7d 0a 25 | 20 5c 62 65 67 69 6e 65 |day#1}.%| \begine|
|00000b20| 76 65 6e 74 73 2e 2e 2e | 5c 65 6e 64 65 76 65 6e |vents...|\endeven|
|00000b30| 74 73 0a 25 20 63 6f 6e | 74 61 69 6e 73 20 63 6f |ts.% con|tains co|
|00000b40| 6e 74 72 6f 6c 20 73 65 | 71 75 65 6e 63 65 73 20 |ntrol se|quences |
|00000b50| 6c 69 6b 65 0a 25 20 5c | 65 76 65 6e 74 20 6f 72 |like.% \|event or|
|00000b60| 20 5c 65 76 64 61 79 20 | 6f 72 20 73 65 71 75 65 | \evday |or seque|
|00000b70| 6e 63 65 73 0a 25 20 67 | 65 6e 65 72 61 74 69 6e |nces.% g|eneratin|
|00000b80| 67 20 74 68 65 73 65 20 | 63 6f 6d 6d 61 6e 64 73 |g these |commands|
|00000b90| 2e 0a 5c 6e 65 77 77 72 | 69 74 65 5c 65 76 65 66 |..\newwr|ite\evef|
|00000ba0| 69 6c 65 0a 5c 64 65 66 | 5c 62 65 67 69 6e 65 76 |ile.\def|\beginev|
|00000bb0| 65 6e 74 73 7b 25 0a 20 | 5c 69 6d 6d 65 64 69 61 |ents{%. |\immedia|
|00000bc0| 74 65 5c 6f 70 65 6e 6f | 75 74 0a 20 5c 65 76 65 |te\openo|ut. \eve|
|00000bd0| 66 69 6c 65 3d 5c 6a 6f | 62 6e 61 6d 65 2e 65 76 |file=\jo|bname.ev|
|00000be0| 65 5c 72 65 6c 61 78 7d | 0a 5c 64 65 66 5c 65 6e |e\relax}|.\def\en|
|00000bf0| 64 65 76 65 6e 74 73 7b | 5c 69 6d 6d 65 64 69 61 |devents{|\immedia|
|00000c00| 74 65 5c 63 6c 6f 73 65 | 6f 75 74 0a 20 5c 65 76 |te\close|out. \ev|
|00000c10| 65 66 69 6c 65 5c 65 6e | 64 7d 0a 5c 6e 65 77 74 |efile\en|d}.\newt|
|00000c20| 6f 6b 73 5c 65 76 65 74 | 65 78 74 0a 5c 64 65 66 |oks\evet|ext.\def|
|00000c30| 5c 65 76 65 6e 74 23 31 | 2f 23 32 5b 23 33 5d 7b |\event#1|/#2[#3]{|
|00000c40| 5c 65 76 65 74 65 78 74 | 3d 7b 23 33 7d 25 0a 20 |\evetext|={#3}%. |
|00000c50| 5c 44 61 79 3d 23 31 5c | 4d 6f 6e 74 68 3d 23 32 |\Day=#1\|Month=#2|
|00000c60| 5c 64 61 79 6e 6f 0a 20 | 5c 65 76 64 61 79 5b 5c |\dayno. |\evday[\|
|00000c70| 74 68 65 5c 65 76 65 74 | 65 78 74 5d 7d 0a 5c 64 |the\evet|ext]}.\d|
|00000c80| 65 66 5c 65 76 64 61 79 | 5b 23 31 5d 7b 5c 69 6d |ef\evday|[#1]{\im|
|00000c90| 6d 65 64 69 61 74 65 5c | 77 72 69 74 65 5c 65 76 |mediate\|write\ev|
|00000ca0| 65 66 69 6c 65 7b 25 0a | 20 5c 73 74 72 69 6e 67 |efile{%.| \string|
|00000cb0| 5c 65 76 65 6e 74 65 6e | 74 72 79 7b 5c 74 68 65 |\eventen|try{\the|
|00000cc0| 5c 64 61 74 65 7d 7b 23 | 31 7d 7d 7d 0a 5c 64 65 |\date}{#|1}}}.\de|
|00000cd0| 66 5c 74 68 65 63 61 6c | 64 61 74 65 7b 5c 74 68 |f\thecal|date{\th|
|00000ce0| 65 5c 44 61 79 2f 5c 74 | 68 65 5c 4d 6f 6e 74 68 |e\Day/\t|he\Month|
|00000cf0| 7d 0a 5c 64 65 66 5c 6d | 75 74 65 7b 5c 64 65 66 |}.\def\m|ute{\def|
|00000d00| 5c 74 68 65 63 61 6c 64 | 61 74 65 7b 7d 7d 0a 25 |\thecald|ate{}}.%|
|00000d10| 0a 25 20 32 6e 64 20 72 | 75 6e 20 63 6f 6d 6d 61 |.% 2nd r|un comma|
|00000d20| 6e 64 73 0a 25 0a 5c 6e | 65 77 63 6f 75 6e 74 5c |nds.%.\n|ewcount\|
|00000d30| 63 75 72 72 65 6e 74 64 | 61 74 65 0a 5c 6e 65 77 |currentd|ate.\new|
|00000d40| 63 6f 75 6e 74 5c 6c 61 | 73 74 64 61 74 65 0a 5c |count\la|stdate.\|
|00000d50| 6e 65 77 63 6f 75 6e 74 | 5c 6e 65 78 74 64 61 74 |newcount|\nextdat|
|00000d60| 65 0a 5c 6e 65 77 69 66 | 5c 69 66 64 6f 69 6e 67 |e.\newif|\ifdoing|
|00000d70| 40 64 61 79 0a 5c 6e 65 | 77 69 66 5c 69 66 68 6f |@day.\ne|wif\ifho|
|00000d80| 6c 79 0a 5c 64 65 66 5c | 68 6f 6c 79 7b 5c 67 6c |ly.\def\|holy{\gl|
|00000d90| 6f 62 61 6c 5c 68 6f 6c | 79 74 72 75 65 7d 0a 5c |obal\hol|ytrue}.\|
|00000da0| 64 65 66 5c 75 70 74 6f | 23 31 7b 5c 6e 65 78 74 |def\upto|#1{\next|
|00000db0| 64 61 74 65 3d 23 31 0a | 20 5c 6c 6f 6f 70 5c 61 |date=#1.| \loop\a|
|00000dc0| 64 76 61 6e 63 65 5c 63 | 75 72 72 65 6e 74 64 61 |dvance\c|urrentda|
|00000dd0| 74 65 20 62 79 31 5c 72 | 65 6c 61 78 0a 20 20 5c |te by1\r|elax. \|
|00000de0| 69 66 6e 75 6d 5c 63 75 | 72 72 65 6e 74 64 61 74 |ifnum\cu|rrentdat|
|00000df0| 65 3c 5c 6e 65 78 74 64 | 61 74 65 0a 20 20 5c 62 |e<\nextd|ate. \b|
|00000e00| 65 67 69 6e 40 64 61 79 | 5c 65 6e 64 40 64 61 79 |egin@day|\end@day|
|00000e10| 5c 72 65 70 65 61 74 7d | 0a 5c 64 65 66 5c 65 76 |\repeat}|.\def\ev|
|00000e20| 65 6e 74 65 6e 74 72 79 | 23 31 23 32 7b 5c 75 6e |ententry|#1#2{\un|
|00000e30| 73 6b 69 70 0a 20 5c 69 | 66 6e 75 6d 23 31 3e 5c |skip. \i|fnum#1>\|
|00000e40| 6c 61 73 74 64 61 74 65 | 5c 65 6c 73 65 0a 20 20 |lastdate|\else. |
|00000e50| 5c 69 66 6e 75 6d 5c 63 | 75 72 72 65 6e 74 64 61 |\ifnum\c|urrentda|
|00000e60| 74 65 3c 23 31 0a 20 20 | 20 5c 69 66 64 6f 69 6e |te<#1. | \ifdoin|
|00000e70| 67 40 64 61 79 5c 65 6e | 64 40 64 61 79 5c 66 69 |g@day\en|d@day\fi|
|00000e80| 0a 20 20 5c 75 70 74 6f | 7b 23 31 7d 5c 66 69 0a |. \upto|{#1}\fi.|
|00000e90| 20 5c 69 66 6e 75 6d 5c | 63 75 72 72 65 6e 74 64 | \ifnum\|currentd|
|00000ea0| 61 74 65 3d 23 31 0a 20 | 20 5c 69 66 64 6f 69 6e |ate=#1. | \ifdoin|
|00000eb0| 67 40 64 61 79 5c 65 6c | 73 65 5c 62 65 67 69 6e |g@day\el|se\begin|
|00000ec0| 40 64 61 79 5c 66 69 0a | 20 20 23 32 5c 70 61 72 |@day\fi.| #2\par|
|00000ed0| 5c 66 69 5c 66 69 7d 0a | 5c 64 65 66 5c 62 65 67 |\fi\fi}.|\def\beg|
|00000ee0| 69 6e 40 64 61 79 7b 5c | 64 6f 69 6e 67 40 64 61 |in@day{\|doing@da|
|00000ef0| 79 74 72 75 65 0a 20 5c | 64 61 74 65 3d 5c 63 75 |ytrue. \|date=\cu|
|00000f00| 72 72 65 6e 74 64 61 74 | 65 5c 63 61 6c 64 61 74 |rrentdat|e\caldat|
|00000f10| 65 0a 20 5c 6d 65 73 73 | 61 67 65 7b 3c 5c 74 68 |e. \mess|age{<\th|
|00000f20| 65 63 61 6c 64 61 74 65 | 7d 5c 62 65 67 69 6e 64 |ecaldate|}\begind|
|00000f30| 61 79 7d 0a 5c 64 65 66 | 5c 65 6e 64 40 64 61 79 |ay}.\def|\end@day|
|00000f40| 7b 5c 65 6e 64 64 61 79 | 5c 64 6f 69 6e 67 40 64 |{\endday|\doing@d|
|00000f50| 61 79 66 61 6c 73 65 0a | 20 5c 67 6c 6f 62 61 6c |ayfalse.| \global|
|00000f60| 5c 68 6f 6c 79 66 61 6c | 73 65 5c 6d 65 73 73 61 |\holyfal|se\messa|
|00000f70| 67 65 7b 3e 7d 7d 0a 5c | 64 65 66 5c 6d 61 6b 65 |ge{>}}.\|def\make|
|00000f80| 61 67 65 6e 64 61 23 31 | 7b 5c 69 6e 70 75 74 20 |agenda#1|{\input |
|00000f90| 23 31 2e 73 74 79 5c 72 | 65 6c 61 78 0a 20 5c 62 |#1.sty\r|elax. \b|
|00000fa0| 65 67 69 6e 40 64 61 79 | 5c 69 6e 70 75 74 5c 6a |egin@day|\input\j|
|00000fb0| 6f 62 6e 61 6d 65 2e 65 | 76 65 5c 72 65 6c 61 78 |obname.e|ve\relax|
|00000fc0| 0a 20 5c 65 76 65 6e 74 | 65 6e 74 72 79 7b 5c 74 |. \event|entry{\t|
|00000fd0| 68 65 5c 6c 61 73 74 64 | 61 74 65 7d 7b 7d 5c 65 |he\lastd|ate}{}\e|
|00000fe0| 6e 64 40 64 61 79 0a 20 | 5c 65 70 69 6c 6f 67 5c |nd@day. |\epilog\|
|00000ff0| 65 6e 64 7d 0a 25 20 44 | 6f 20 6e 6f 74 20 72 65 |end}.% D|o not re|
|00001000| 61 64 20 65 76 65 6e 74 | 73 0a 5c 64 65 66 5c 6d |ad event|s.\def\m|
|00001010| 61 6b 65 65 6d 70 74 79 | 7b 5c 62 65 67 69 6e 40 |akeempty|{\begin@|
|00001020| 64 61 79 0a 20 5c 65 76 | 65 6e 74 65 6e 74 72 79 |day. \ev|ententry|
|00001030| 7b 5c 74 68 65 5c 6c 61 | 73 74 64 61 74 65 7d 7b |{\the\la|stdate}{|
|00001040| 7d 5c 65 6e 64 40 64 61 | 79 7d 0a 5c 63 61 74 63 |}\end@da|y}.\catc|
|00001050| 6f 64 65 60 5c 40 3d 31 | 32 0a |ode`\@=1|2. |
+--------+-------------------------+-------------------------+--------+--------+